﻿using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace NCS.DeviceManager.Models.Entities
{
    [Table("tbl_document")]
    public class DocumentEntity:BaseEntity
    {
        /// <summary>
        /// 文件名
        /// </summary>
        [MaxLength(1024), Required]
        public string FileName { get; set; }
        /// <summary>
        /// 文件类型
        /// </summary>
        [MaxLength(64), Required]
        public string FileType { get; set; }
        /// <summary>
        /// 服务器地址
        /// </summary>
        [MaxLength(1024), Required]
        public string ServicePath { get; set; }
        /// <summary>
        /// 扩展名
        /// </summary>
        [MaxLength(8), Required]
        public string Extension { get; set; }
        /// <summary>
        /// 内容
        /// </summary>
        public byte[] Content { get; set; }
        /// <summary>
        /// Hash编码
        /// </summary>
        [MaxLength(64), Required]
        public string HashCode { get; set; }
    }
}
